package com.itheima.mapper;

import com.itheima.domain.Admin;
import com.itheima.domain.User;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

//持久层接口
public interface UserMapper {



    @Select("select * from admin where email=#{email} and password=#{pwd}")
    Admin findByEmailAndPwd(@Param("email") String email, @Param("pwd") String pwd);


    //获取所有用户
    @Select("select * from user")
    List<User> findAll();
}
